//
//  CoverInfoCell.swift
//  Mediaplayer
//
//  Created by bin hu on 2025/7/9.
//

import UIKit

class CoverInfoCell: UICollectionViewCell {
    
    private lazy var coverImgView:UIImageView = {
        let v = UIImageView()
        return v
    }()
    
    private lazy var titleLabel:UILabel = {
        let lbl = UILabel()
        lbl.text = "akjglhsaklghsa;gjkas;gfjkasg"
        return lbl
    }()
    
    override init(frame: CGRect) {
        super.init(frame: frame)
        
        coverImgView.theme_backgroundColor = "Colors.swapred"
        
        contentView.addSubview(coverImgView)
        contentView.addSubview(titleLabel)
        
        titleLabel.snp.makeConstraints { make in
            make.left.right.equalToSuperview().inset(10)
            make.height.equalTo(20)
            make.bottom.equalToSuperview()
        }
        
        coverImgView.snp.makeConstraints { make in
            make.left.right.top.equalToSuperview()
            make.bottom.equalTo(titleLabel.snp.top)
        }
        
        coverImgView.layercornerRadius(cornerRadius: 10)
    }
    
    required init?(coder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
}
